Image layers have been developed as a way to simplify editing of the image by a user. For example, an image may be formed from a background layer, such as a forest scene, over which additional layers are “stacked” that have additional objects such as birds, kites, and so forth to render the image in a final viewable form. Because these layers are separated, one from another, changes may be made to one layer without directly interacting with another layer. Continuing with the previous example, a user may desire to change a type of bird included in the image as well as a location of the bird. To do so, the user may replace or modify the layer having the bird to replace the unwanted bird with the desired bird at a desired location. The layers may then be rendered to achieve a desired final output, e.g., the bird displayed over the forest scene.
Conventional techniques to render layers of an image, however, may exhibit unwanted “bleed through” of underlying objects. This is particularly troublesome in conventional techniques at shared edges between two objects in the image. In one conventional example, objects are rendered, one at a time, with source colors blended using multiplicative blending with the destination for each object that shares the edge. This may cause color of an underlying object to be incorporated at the intersection of the shared edges. For instance, two rectangles may include a shared edge, such as walls of a house over a background of a sky. Conventionally, the first rectangle is first rendered in relation to a background of the image. Because the first rectangle in this conventional example may not consume an entire display area of the pixel along the shared edge, however, colors of the background are blended with colors of this first rectangle to arrive at an initial color value for that pixel.
This process is then continued for the second rectangle. However, because these rectangles are rendered separately with alpha based color blending, the previous color value for the first rectangle that includes part of the background is blended with a color value for the second rectangle. This may even continue through successive layers of the image such that the background color is further incorporated upward through the layers. In this way, color values of the background may bleed “up through” the intersecting objects when rendered using this conventional technique. Thus, in this example this may result in artifacts in which a color value of the “sky” of the background bleeds through the shared edge of the walls formed by the first and second rectangles, which is unrealistic and departs from user expectations in viewing the image.